<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0" />
    <meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
    <title>饿了么</title>
    <link rel="stylesheet" type="text/css" href="../../css/aui.css" />
    <style media="screen">
        html,
        body {
            width: 100%;
            height: 100%;
            background: linear-gradient(180deg, #0058E6 0%, #166CFF 100%);
        }

        .wrap {
            width: 100%;
            padding: 0 27px;
            box-sizing: border-box;
            overflow: hidden;
        }

        .wrap .ele {
            width: 90px;
            height: 39px;
            background: url(../../image/ele.png) no-repeat;
            background-size: 100% 100%;
        }

        .onceget {
            width: 100%;
            padding: 0 18.5px;
            box-sizing: border-box;
            height: 78px;
            background: #fff;
            box-shadow: 2px 4px 16px 0px rgba(1, 143, 243, 0.25), -5px -5px 35px 0px rgba(1, 143, 243, 0.14);
            border-radius: 15px;
            display: flex;
            justify-content: space-between;
            margin-top: 25px;
        }

        .onceget_l {
            width: 100%;
            overflow: hidden;
            display: flex;
        }

        .onceget_l span {
            width: auto;
            height: 20px;
            line-height: 20px;
            font-size: 17px;
            font-family: PingFang SC;
            font-weight: 500;
            color: #333333;
            margin-top: 29px;
        }

        .onceget_r {
            width: 87px;
            height: 34px;
            line-height: 34px;
            text-align: center;
            color: #fff;
            font-size: 12px;
            background: linear-gradient(269deg, #008FF3, #018FF3);
            box-shadow: 2.5px 5px 13.5px 0px rgba(3, 143, 243, 0.5);
            border-radius: 17px;
            margin-top: 22px;
        }

        .cash_back {
            width: 100%;
            padding: 20.5px 34px 22px 34px;
            background: #fff;
            border-radius: 15px;
            margin-top: 10px;
            overflow: hidden;
        }

        .cash_back .title {
            width: 100%;
            /*display: flex;*/
            /*padding: 0 38px;*/
            text-align: center;
            overflow: hidden;
        }

        .cash_back .title div {
            width: auto;
            height: 17px;
            line-height: 17px;
            font-size: 16px;
            font-family: PingFang SC;
            font-weight: 500;
            color: #333333;
        }

        .cash_back .title div span {
            color: #FB0000!important;
        }

        .step {
            width: 100%;
            display: flex;
            justify-content: space-between;
            margin-top: 20px;
            overflow: hidden;
        }

        .step span.text {
            height: 12px;
            line-height: 12px;
            font-size: 11px;
            font-family: PingFang SC;
            font-weight: 400;
            color: #F1671E;
        }

        .step span.line {
            width: 38px;
            height: 1px;
            margin-top: 5.5px;
            background: #F1671D;
        }

        .step1 span.text {
            color: #333333;
        }
        /*.step1 span.text:first-child{
          width: 47px;
          text-align: center;
        }*/

        .rules {
            width: 100%;
            padding: 21px 13.5px;
            background-color: #fff;
            border-radius: 10px;
            margin-top: 10px;
            margin-bottom: 13.5px;
            overflow: hidden;
        }

        .rules .title {
            width: 100%;
            height: 17px;
            line-height: 17px;
            text-align: center;
            font-size: 16px;
            font-family: PingFang SC;
            font-weight: 500;
            color: #333333;
        }

        .rules .content p {
            width: auto;
            overflow: hidden;
            font-size: 14px;
            font-family: PingFang SC;
            font-weight: 500;
            color: #656565;
            margin-top: 5px;
        }

        .rules .content p:first-child {
            margin-top: 0;
        }

        .caption {
            width: 100%;
            margin-top: 18px;
            overflow: hidden;
        }

        .caption .caption_t {
            width: 100%;
            height: 17px;
            font-size: 16px;
            font-family: PingFang SC;
            font-weight: 500;
            color: #FFFFFF;
            line-height: 17px;
        }

        .caption .caption_t span {
            color: #FC0000;
        }
        .caption .caption_t:last-child{
          margin-top: 12px;
          padding-left: 80px;
          box-sizing:border-box;
        }
        .rob{
          width: 97px;
          height: 82px;
          background: url(../../image/rob.png) no-repeat;
          background-size: 100% 100%;
          position: absolute;
          top: 0;
          right: 15px;
        }
    </style>
</head>

<body>
    <div id="app">
        <div class="wrap">
            <div class="ele"></div>
            <div class="caption">
                <div class="caption_t">最高领<span>38</span>元红包</div>
                <div class="caption_t">下单最高返利<span>5%</span></div>
            </div>
            <div class="rob"></div>
            <div class="onceget">
                <div class="onceget_l">
                    <span>最高可领取</span>
                    <span style="color:#FB0000;font-size:20px;line-height:20px;">66</span>
                    <span>元满减券</span>
                </div>
                <div class="onceget_r" @click='shareGetMoney(0)'>立即领券</div>
            </div>

            <div class="cash_back">
                <div class="title">
                    <div class="tilte_l">领券下单最高享省<span>5%</span></div>
                    <!-- <div class="title_r"></div> -->
                </div>
                <div class="step" style="padding:0 8px;">
                    <span class="text">第1步</span>
                    <span class="line"></span>
                    <span class="text">第2步</span>
                    <span class="line"></span>
                    <span class="text">第3步</span>
                </div>
                <div class="step step1" style="margin-top:13.5px;">
                    <span class="text">当前页面 </span>
                    <span class="text">饿了么外卖</span>
                    <span class="text">最高省</span>
                </div>
                <div class="step step1" style="padding:0 10px;margin-top:5px;">
                    <span class="text">领券</span>
                    <span class="text">用券下单</span>
                    <span class="text" style="color:#F1671E;">5%</span>
                </div>
                <div class="title" style="margin-top:22px;">
                    <div class="tilte_l">分享好友最高享省<span>5%</span></div>
                    <!-- <div class="title_r">5%</div> -->
                </div>
                <div class="step" style="padding:0 8px;">
                    <span class="text">第1步</span>
                    <span class="line"></span>
                    <span class="text">第2步</span>
                    <span class="line"></span>
                    <span class="text">第3步</span>
                </div>
                <div class="step step1" style="padding-left:11px;margin-top:13.5px;">
                    <span class="text">微信&nbsp&nbsp</span>
                    <span class="text">&nbsp&nbsp饿了么外卖 </span>
                    <span class="text">最高省</span>
                </div>
                <div class="step step1" style="padding:0 10px;margin-top:5px;">
                    <span class="text">分享</span>
                    <span class="text">好友用券下单</span>
                    <span class="text" style="color:#F1671E;">5%</span>
                </div>
            </div>

            <div class="rules">
                <div class="title">活动规则</div>
                <div class="content" style="margin-top:16px;">
                    <p>1、本次活动中红包领取时间截止至2020年12月31日24点;</p>
                    <p>2、订单同步为次日，例如12日下的订单，在13日24:00前可同步到返佣订单;</p>
                    <p>3、红包可在饿了么或饿了么外卖最新版客户端、饿了么小程序下单且选择在线支付时使用;</p>
                    <p>4、红包仅限非到店自取外卖订单，下午茶、夜宵、美食、蛋糕、团餐频道、甜点饮品频道使用;</p>
                    <p>5、外卖新人首单红包限新用户(设备、手机号、饿了么账号均未在饿了么外卖下过单)首次下单使用，且不与其他优惠 (首减、满减、满赠、套餐增、折扣菜)同享;</p>
                    <p>6、使用红包时下单手机号码必须与收餐人手机号码、领取</p>
                </div>
            </div>
        </div>
    </div>
</body>
<script type="text/javascript" src="../../script/api.js"></script>
<script type="text/javascript" src="../../script/vue.js"></script>
<script type="text/javascript" src="../../script/cling.js"></script>
<script type="text/javascript">
    apiready = function() {

    }
    var vm = new Vue({
        el: '#app',
        data: {

        },
        methods: {
          shareGetMoney: function(index) {
              api.ajax({
                  url: cl.apiServer + 'tb/activityLink',
                  method: 'post',
                  headers: {
                      'Content-Type': 'application/json;charset=utf-8',
                      token:cl.userToken
                  },
                  data: {
                      body: {
                          "platform": "2",
                          "promotionSceneId": "1571715733668",
                          "title": "拼手速，抢饿了么大额红包！",
                          "unionId": "饿了么福利红包每日领",
                          "version":cl.deviceInfo().appVersion,
                          "mobileInfo":cl.systemType()
                      }
                  }
              }, function(ret, err) {
                  console.log(JSON.stringify(ret))
                  if (ret.code == 0) {
                    if(index==0){
                      cl.openAlert({
                          title: ret.data.Tpwd,
                          content: '复制淘口令,打开手机淘宝，抢饿了么大额红包！',
                          rightBtnTitle: '立即复制'
                      }, function(res) {
                          if (res.eventType === "right") {
                              var clipBoard = api.require('clipBoard');
                              clipBoard.set({
                                  value: ret.data.longTpwd
                              }, function(ret, err) {
                                  if (ret) {
                                      // alert(JSON.stringify(ret));
                                      if (ret.status) {
                                          clipBoard.get(function(ret, err) {
                                              if (ret) {
                                                  cl.toast({
                                                      msg: '复制成功'
                                                  })
                                              } else {
                                                  // alert(JSON.stringify(err));
                                              }
                                          });
                                      }
                                  } else {
                                      alert(JSON.stringify(err));
                                  }
                              });
                          }
                      });
                    }else{
                      cl.openWin({
                          name: '../../brower',
                          pageParam: {
                              link:ret.data.click_url
                          }
                      })
                    }

                  }
              })
          }
        }
    });
</script>

</html>
